<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <h1>退出成功！</h1>
    <p></p>
    <script>
        let num = 3;

        let p = document.querySelector('p');
        p.innerHTML = num+'秒后跳转到首页';

        setInterval(() => {
            num--
            p.innerHTML = num+'秒后跳转到首页';
        }, 1000);

        setTimeout(() => {
            window.location.href = 'http://localhost';
        }, 3000);
    </script>
</body>
</html>